<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>原生Promise</title>
  </head>
  <body></body>

  <script>
    let p = new Promise((resolve, reject) => {
      // resolve("后盾人");
      reject("向边");
    });
    Promise.resolve(p).then(
      (value) => {
        console.log(value);
      },
      (reason) => {
        console.log(reason);
      }
    );
    Promise.reject("hdcms").then(null, (reason) => {
      console.log(reason);
    });
  </script>
</html>
